home *** CD-ROM | disk | FTP | other *** search
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- TheGrin Version 1.02
- Macintosh (tm) Picture File Viewer/Printer
-
- COPYRIGHT (C) 1986,87
- TheSoft Programming Services and Ian E. Davis
-
- All rights reserved by TheSoft Programming Services
-
-
-
- Written in Turbo Pascal on a Tandy 1000
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- I N T R O D U C T I O N:
-
-
- TheGrin was written because no other program really provided the
- features I wanted. To give credit where its due, TheGrin is
- derived from the public domain program MacView, although at this
- stage there isn't a single byte that remains the same. MacView
- allowed simple picture viewing, and it contains a bug which
- limits that ability. TheGrin corrects that problem, and adds
- multiple facilities for enlarging, shrinking, and printing of
- pictures.
-
- TheGrin divides the enlargement and shrinking of images into two
- commands: Expanding and Squashing. Expanding works horizontally
- only. If you specify to expand the image by a factor of two,
- TheGrin will only make it horizontally twice as wide as before.
- Since expanding an image is a time consuming process, any changes
- made are permanent.
-
- TheGrin goes beyond other programs in its expanding capacity. It
- can handle a -variable- expand from a factor of 0.10 to 8.00.
- Other programs I've seen only allow 50% (1.5) or 100% (2.0)
- expansion. With flexibility however, TheGrin takes about 10
- seconds to expand something. However, factor two expansions are
- done most often and are optimized to work in two seconds.
-
- Squashing as you might guess works vertically. Similar to
- expanding, a squash factor of two makes a picture twice as long
- without adjusting the width. Unlike expanding, squashing is fast
- and done in real time. What this means is you can repeatedly
- change the squash factor without losing resolution in the
- picture. Other programs physically squash the picture. If they
- run out of buffer space, you picture stops there. TheGrin avoids
- that problem entirely.
-
- As they come from a Mac, picture files appear distorted on a PC
- screen. This is because the aspect ratio is different. You can
- correct the aspect ratio by either specifying a squash factor of
- 0.5 or an expand factor of 2.0. The best way to get a good feel
- for these commands is to use them.
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- TheGrin Page 1
-
-
-
-
-
-
-
-
-
- I N T R O D U C T I O N (cont):
-
-
- Printing is another area where TheGrin leaves the others behind.
- TheGrin has a limited buffer space. Expanding an image uses some
- of that space, thus reducing the length on an image. If you want
- to print something with the aspect ratio corrected, you can
- either squash the picture then print (making a small image), or
- expand it and print (making a large picture, but chopped off).
-
- TheGrin gets around this by giving you a choice. You can either
- print whats in the buffer, or request a [F]ull enlargement. What
- that does is reload the picture, then squash/expand it as the
- printing progresses. Neat stuff huh? Better still, if the image
- on screen is wider than your printer, you can print the image in
- -columns-, then tape them together for a huge printout.
- Conceivably a WALL SIZE picture is possible although it takes a
- few hours to print out.
-
- Other features are available in the program. You can blowup on
- an image (squash and expand at the same time), zoom in on a
- particular feature and other things. Enjoy!
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- TheGrin Page 2
-
-
-
-
-
-
-
-
-
- C O M M A N D S:
-
-
- The following commands are available while using TheGrin:
-
- [B] - Blow up image 100%
- [C] - Configure TheGrin (printer)
- [D] - Dump current screen to Disk
- [E] - Expand image (horizontal)
- [L] - Load new picture file
- [P] - Print current picture
- [S] - Specify new squash factor
- [Z] - Zoom on any part of image.
-
- In addition, other keys are assigned various functions:
-
- F5 - Expand image 50%
- F6 - Expand image 100%
- F9 - Squash image 50%
- F10 - Reload current picture
-
- PgUp - Move up 1/2 screen
- PgDn - Move down 1/2 screen
- Home - Go to top of file
- End - Go to bottom of file
-
- ESC - Exit TheGrin
-
- The arrow keys may be used for moving around the image also. The
- command functions are described on the following pages.
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- TheGrin Page 3
-
-
-
-
-
-
-
-
-
- [B] - Blow Up Image 100%
-
- This is a fairly straight forward function. It makes the current
- image four times larger by using an expand/squash factor of 2.0.
- You might use this command for quickly enlarging a picture to a
- desired size. Other programs always start from the top of a
- picture and work down until they run out of space. TheGrin
- starts from where the top of the SCREEN is current located in the
- picture. This allows you to more closely examine those parts a
- bit further down.
-
-
- [C] - Configure TheGrin
-
- This command allows you to configure TheGrin to your printer.
- You do this by specifying three control sequences and other
- parameters to TheGrin:
-
- [A] - Normal linespacing (1/6th inch)
- [B] - Graphics linespacing (around 1/8th inch)
- [C] - Select 120 DPI graphics mode
-
- [D] - Printer Width (in inches)
- [T] - Printer Description/Title
-
- Codes for the first three may be found in your printer manual.
- An escape code (27 decimal) is always sent before these control
- sequences so you don't need to enter it. TheGrin comes
- configured for the IBM Graphics printer, however I believe the
- same codes are used in Epson printers and others. Check to see
- before changing anything.
-
- Parameter [C] is only the code for selecting 120 DPI mode.
- TheGrin assumes the printer needs a byte count of the graphics
- data the immediately following the control codes. ie:
-
- <Escape><Parameter [C] codes><Byte Count><Graphics Data....>
-
- The byte count is sent in least significant byte (LSB), most
- significant byte (MSB) order.
-
- After you enter the appropriate codes, you must tell TheGrin the
- width of your printer in inches. This is so TheGrin knows when
- to stop sending graphics data and to print multi-column prints.
- Next, change the printer [T]itle so anyone you give the program
- to knows what they're getting. Lastly, to make sure you don't
- have to reenter this stuff again, [S]ave the configuration to the
- file TG.COM (must be present in current directory).
-
-
-
-
-
-
-
-
- TheGrin Page 4
-
-
-
-
-
-
-
-
-
- [D] - Dump Current Screen Image
-
- This is another fairly straight forward function. It simply
- dumps the current screen contents to disk. Note, the entire
- picture is NOT saved, only what is physically on the screen at
- the time. You are first prompted for a valid filename, then you
- can choose one of two modes for saving the image: Binary or
- BSave (for Basic). Other modes (ie: for Assembler or Pascal)
- were not included as putting a 16k screen image chunk in the
- middle of a program is not practical. I'm not fixed on this
- though, and am always willing to add other functions.
-
-
-
- [E] - Expand Image Horizontally
-
- Expanding was described in the introduction and is more or less
- repeated here. TheGrin divides the enlargement and shrinking of
- images into two modes. Expanding and Squashing. Expanding
- works horizontally only. If you specify to expand the current
- image by a factor of two, TheGrin will only make it horizontally
- twice as wide as before. The larger the number, the more
- expanded the image will become.
-
- Since expanding an image is a time consuming process, any changes
- made are permanent. This is unlike the squash factor which is
- done in real time since it occurs very fast.
-
- TheGrin goes beyond other programs in its expanding capacity. It
- can handle a -variable- expand from a factor of 0.10 to 8.00.
- ANY number in between is acceptable up to about 4 decimal places
- or so (ie: 1.667 is ok). Other programs I've seen only allow
- fixed 50% or 100% expansion.
-
- With flexibility however, TheGrin runs slightly slower taking
- about 10 seconds to expand something. Since expanding by factor
- two is done most often, certain code is optimized to finish that
- in under two seconds.
-
- The best way to get a good feel for what is possible is to play
- with it. Try entering large and small numbers. Anything over
- 1.0 will make the picture wider, while numbers under 1.0 will
- crunch it.
-
-
-
-
-
-
-
-
-
-
-
-
-
- TheGrin Page 5
-
-
-
-
-
-
-
-
-
- [L] - Load a New Picture
-
- Yet another "fairly straight forward function"! This one prompts
- for a valid filename then loads a new file. That is it. Period.
- Nothing else. Zip.
-
-
- [P] - Print Picture
-
- The printing ability of TheGrin is moderately sophisticated in
- that it can handle expanding, squashing, and multi-column print
- outs all at the same time. If the image has been adjusted in any
- way you are prompted if you want the current [I]mage or [F]ull
- enlargement to be done.
-
- The image mode takes the current buffer contents without changing
- anything. A full enlargement however reloads the image and
- expands/squashs the image to whatever the current settings were
- before. This allows you to make mammoth picture if you had the
- need. The biggest I've personally made is a wall-size poster
- three 132-column pages across and about 7 pages long. It also
- took three hours to print out, so be warned.
-
- There is a side effect to using the full enlargement however, you
- lose any squash/expanding settings that were in place. You have
- to manually reset them. The best thing to do is use the image
- printout until you get what you want, then as a last step use the
- full enlargement.
-
- If at anytime a given image would produce something wider than
- your printer, you are given the option of printing the picture in
- columns. This prints the left-most section of the picture first,
- does a formfeed, then the second section, and so on until it is
- all printed. It can be quite useful, especially for those users
- of 80 column printers.
-
- At any time during a printout, you can abort by pressing [ESC].
- Since many pictures have nothing but white space for the last few
- lines, this can be used to save time. Don't press [ESC] during a
- multi-column print out however, until you are certain you are on
- the last page.
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- TheGrin Page 6
-
-
-
-
-
-
-
-
-
- [S] - Specify Vertical Squash Factor
-
- This command is the counterpart of the expand function. It works
- similarly except in the vertical direction.
-
- A squash factor of two makes a picture twice as long without
- adjusting the width, and the larger the number, the longer the
- picture. Unlike expanding, squashing is very fast and done in
- real time. What this means is you can repeatedly change the
- squash factor without losing resolution in the picture. Other
- programs physically alter the data, losing picture information.
- If they run out of buffer space, you picture stops there.
- TheGrin avoids that problem entirely.
-
- Again, the best way to get a good feel for what is possible is to
- play with it. Try large and small numbers. Anything over 1.0
- will make the picture longer, while numbers under 1.0 will
- shorten it. Remember, any number you enter is relative to what
- the picture looked like when you LOADED it. Therefore, entering
- a squash factor of 1.0 shows what it originally looked like.
-
-
-
- [Z] - Zoom on Any Part of Image
-
- This command is the most fun to play with. It allows you to
- select a particular part of an image to enlarge. First a window
- the full size of the screen appears. You then contract that
- window using the arrow keys. If you overshoot your target, you
- can start over by pressing the [Home] key. One you get it over
- the wanted part, press [Enter]. The image is expanded and
- squashed the appropriate amount (takes about 10 secs) and the
- image is displayed. Similar to the blowup command, the top edge
- of the selected window becomes the top edge of the picture.
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- TheGrin Page 7
-
-
-
-
-
-
-
-
-
- T H E N A M E ? ? ?
-
-
- No doubt there are people wondering where on earth I devised an
- odd name like TheGrin. It worked like this... Along with a
- couple of friends, I was trying to thing of what the new monster
- should be called. TheMac sounded too, well, plain. We realized
- what most people would be doing once they started to play with
- the program <grin>. Therefore a name was born!
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- TheGrin Page 8
-
-
-
-
-
-
-
-
-
- P R O G R A M H I S T O R Y:
-
-
- Version 1.00 - Initial Release
-
- Version 1.01 - Added the blowup and zoom commands.
-
- Version 1.02 - Added printer routines and fixed glitch to stop
- expander doing some funky expanding.
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- TheGrin Page 9
-
-
-
-
-
-
-
-
-
- C O M M E N T S
-
- That is all these is to it. Please consider the donation of $10
- (or any amount). Quality software at good prices is difficult to
- find these days. We at TheSoft Programming Services firmly
- believe in and support the concept of shareware products, and
- hopefully you do also. Please make any checks out to TheSoft
- Programming Services. If you have any requests, comments or
- suggestions for TheGrin, please send them to:
-
-
-
- TheSoft Programming Services
- c/o Ian Davis
- 1929 Whitecliff Court
- Walnut Creek, Ca, 94596.
-
-
-
- Thanks for your support!
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- Macintosh (tm) is a trademark of Apple Computers Inc.
-
-
-
-
-
-
-
- TheGrin Page 10
-
-
-
-
-
-